/**
 * Google统计分析工具
 */
export default class GaUtil {

    static addEvent({eventAction, eventLabel, eventValue = 1, dimension3}) {
        const config = window.config || {userID: ""};
        if (process.env.NODE_ENV === 'production') {
            window.ga && window.ga('send', 'event', {
                eventCategory: '公众号管理',
                eventAction,
                eventLabel,
                eventValue,
                dimension6: '运营', //config.systemCode,
                dimension7: dimension3 || config.userID,   // config.platform,
            });
        } else {
            console.log(`Send to GA: [公众号管理] ${eventAction} : ${eventLabel} : ${eventValue}`)
        }
    }

}